<template>
<section class="screen" ref="sectionRef" v-bind="setSectionRef">
    <div class="screenIn">
        <h2>Section 5 Content</h2>
        <p>Welcome to Section 5!</p>
    </div>
</section>
</template>

<script setup>
 import { ref, onMounted } from 'vue'
  const props = defineProps({
    setSectionRef: {
      type: Function,
      required: true
    }
  });

  const sectionRef = ref(null);

  onMounted(() => {
    props.setSectionRef(sectionRef.value); // 将分屏 ref 传递给父组件
    console.log('分屏 4 渲染:', sectionRef.value);

  });
</script>

<style scoped>
</style>
  